let co = require('co');
let httpClient = require('urllib').create();

const $packageInfo = require('./package.json');
const host = "http://bugatti.dev.qianmi.com/v1/project/version";


co((function *() {
  try {
    httpClient.request(host, {
      method: "post",
      data: {
        version: $packageInfo.version,
        projectName: "admin_d2c_web",
        authToken: "ecd39a460ae901b39d1b997d4a1566e2",
        groupId: "com.qianmi",
        artifactId: "admin-d2c-webapp"
      }
    });
  } catch (err) {
    console.error(err);
  }
})());